import { Injectable } from '@nestjs/common';
import { ResData } from 'src/utils/com';
import { CreateRchyDto } from './dto/create-rchy.dto';
import { UpdateRchyDto } from './dto/update-rchy.dto';
import contactData from './ContactData';
import { ContactRes, ContactDto } from './dto/rchy.dto';

@Injectable()
export class RchyService {
  getContact() {
    const data: {
      list: ContactDto[];
    } = {
      list: contactData,
    };
    return ResData(data) as ContactRes;
  }
  create(createRchyDto: CreateRchyDto) {
    return 'This action adds a new rchy';
  }

  findAll() {
    return `This action returns all rchy`;
  }

  findOne(id: number) {
    return `This action returns a #${id} rchy`;
  }

  update(id: number, updateRchyDto: UpdateRchyDto) {
    return `This action updates a #${id} rchy`;
  }

  remove(id: number) {
    return `This action removes a #${id} rchy`;
  }
}
